<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<t:base type="jquery,easyui,tools,DatePicker"></t:base>
<script type="text/javascript">
    $(function() {
        mallEtcApplyModule.init();
    });
    var mallEtcApplyModule = (function(){

        /*初始化时间查询*/
        var initDate = function(){
            $("input[name='applytime_begin']").attr("class","Wdate").click(function(){WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'});});
            $("input[name='applytime_end']").attr("class","Wdate").click(function(){WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'});});
        }


        var module = {
            init :function(){
                initDate();
            },

            //配置卡号
            configEtcCard : function(id){
                console.log(id);

                window.location.href = 'mallEtcApplyController.do?configetcview&id='+id;
            }
/*
            //导出文件
            exportFile : function (){
                window.location.href = 'mallReportController.do?middleExpenditureExport&'+$("#middleExpenditureListForm").serialize();
            }*/

        }
        return module;
    })();
</script>
<div class="easyui-layout" fit="true">
  <div region="center" style="padding:0px;border:0px">
  <t:datagrid name="mallEtcApplyList" title="ETC卡申请管理" actionUrl="mallEtcApplyController.do?datagrid"
              idField="id" fit="true" queryMode="group">
   <t:dgCol title="编号" field="id" hidden="true"></t:dgCol>
   <t:dgCol title="申请人" field="mallUser.fullname"   width="40"></t:dgCol>
   <t:dgCol title="申请单号" field="applyno" query="true"  width="100"></t:dgCol>
   <t:dgCol title="车牌号" field="carno" query="true"  width="50"></t:dgCol>
   <t:dgCol title="店铺" field="shop.shopname" query="true"  width="100"></t:dgCol>
   <t:dgCol title="行驶证" field="vehiclelicenseimg"  image="true" imageSize="50,50"   width="60"></t:dgCol>
   <t:dgCol title="身份证正面" field="idCardNoHeadsImg"  image="true" imageSize="50,50"   width="60"></t:dgCol>
   <t:dgCol title="身份证反面" field="idCardNoTailsImg"  image="true" imageSize="50,50"   width="60"></t:dgCol>
   <t:dgCol title="车辆照片" field="vehicleimg" image="true" imageSize="50,50"   width="60"></t:dgCol>
   <t:dgCol title="状态"  replace="已申请未支付_0,已支付未受理_1,待发卡_2,待收货_3,已收货_4,商户审核未通过_10,已取消_11"
            field="state" query="true"  width="70"></t:dgCol>
   <t:dgCol title="拒绝原因" field="refectreason"   width="100"></t:dgCol>
   <t:dgCol title="取消原因" field="cancelreason"   width="100"></t:dgCol>
   <t:dgCol title="ETC卡号" field="ectcardno"   width="120"></t:dgCol>
   <t:dgCol title="领卡方式" field="receivetype"  query="true" replace="现场领卡_0,邮寄_1"  width="40"></t:dgCol>
   <t:dgCol title="申请时间" field="applytime" query="true" queryMode="group" formatter="yyyy-MM-dd hh:mm:ss"  width="80"></t:dgCol>
   <%--<t:dgCol title="首次领卡订单id" field="orderid"   width="120"></t:dgCol>--%>
  <%--/*邮寄地址*/
  private java.lang.Integer mailingAddressId;--%>
   <t:dgCol title="操作" field="opt" width="100"></t:dgCol>
  <%-- <t:dgDelOpt title="删除" url="mallEtcApplyController.do?del&id={id}" />--%>
   <t:dgFunOpt funname="mallEtcApplyModule.configEtcCard(id)" title="发卡" exp="state#eq#2"></t:dgFunOpt>
   <%--<t:dgToolBar title="录入" icon="icon-add" url="mallEtcApplyController.do?addorupdate" funname="add"></t:dgToolBar>
   <t:dgToolBar title="编辑" icon="icon-edit" url="mallEtcApplyController.do?addorupdate" funname="update"></t:dgToolBar>--%>
   <t:dgToolBar title="查看" icon="icon-search" url="mallEtcApplyController.do?addorupdate" funname="detail"></t:dgToolBar>
  </t:datagrid>
  </div>
 </div>